import requests
class shopcenter_add:
    def __init__(self):
        self.host = "http://192.168.4.108"
        self.s=requests.session()
        param={'name':'admin','password':'123456'}
        re=self.s.post(url=self.host+"/TinyShop//index.php?con=admin&act=check",data=param)
        # print(re.text)
    def shop_add(self,m):
        shop_url=self.host+"/TinyShop//index.php?con=customer&act=customer_save"
        re=self.s.post(shop_url,m)
        # print(re.text)
        return re.text
# if __name__=="__main__":
#     b=shopcenter_add()
#     b.login()
#     b.shop_add({'name':'admin','password':'123456','repassword':'123456','email':'133478%40qq.com','real_name':'x',
#                             'sex':'0','birthday':'1993-12-21','province':'350000','city':'350100','county':'350103','addr':'','phone':'13423231111','mobile':'7878564','point':'0'})